class AddForeignKeys < ActiveRecord::Migration
  def self.up
    add_column :articles, :section_id, :integer, :null => false
    add_column :sections, :issue_id, :integer, :null => false
    add_column :issues, :volume_id, :integer, :null => false
  end

  def self.down
    remove_column :articles, :section_id
    remove_column :sections, :issue_id
    remove_column :issues, :volume_id
  end
end
